package tr.edu.metu.is.mega.client.service;

import tr.edu.metu.is.mega.common.dto.UserDTO;

import com.extjs.gxt.ui.client.data.PagingLoadConfig;
import com.extjs.gxt.ui.client.data.PagingLoadResult;
import com.google.gwt.user.client.rpc.AsyncCallback;

public interface GwtUserServiceAsync {

    /**
     * @see GwtUserService#login(String, String)
     */
    void login(String userid, String password, AsyncCallback<UserDTO> callback);

    /**
     * @see GwtUserService#getUsers(PagingLoadConfig, UserDTO)
     */
    void getUsers(PagingLoadConfig config, UserDTO filter, AsyncCallback<PagingLoadResult<UserDTO>> callback);

    /**
     * @see GwtUserService#updateUser(UserDTO)
     */
    void updateUser(UserDTO user, AsyncCallback<UserDTO> callback);

    /**
     * @see GwtUserService#deleteUser(UserDTO)
     */
    void deleteUser(UserDTO user, AsyncCallback<Void> callback);

    /**
     * @see GwtUserService#createUser(UserDTO)
     */
    void createUser(UserDTO user, AsyncCallback<UserDTO> callback);

}
